/*
 * @Autor: dingxiaolin
 * @Date: 2021-06-02 13:12:43
 * @LastEditors: dingxiaolin
 * @LastEditTime: 2021-06-05 08:29:09
 */
import { markRaw } from 'vue'
import { RouteRecordRaw } from 'vue-router'
import { RouterTransition } from '@/components/transition'
import { h } from 'vue'

const routeName = 'dashboard'

const routes: Array<RouteRecordRaw> = [
    {
        path: '/dashboard',
        name: routeName,
        redirect: '/dashboard/welcome',
        component: h(markRaw(RouterTransition), { notNeedKey: true }),
        meta: {
            title: '系统看板',
            icon: 'icon-yibiaopan'
        },
        children: [
            {
                path: 'welcome',
                name: `${routeName}-welcome`,
                meta: {
                    title: '首页',
                    icon: 'icon-shouye'
                },
                component: () =>
                    import(
            /* webpackChunkName: "dashboard-welcome" */ '@/views/static_view/welcome/index.vue'
                    )
            }
        ]
    }
]

export default routes
